package com.cyj.service.impl;

import com.cyj.dao.AdminDao;
import com.cyj.entity.Admin;
import com.cyj.service.AdminService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import java.util.Map;

@Service("adminService")
@Transactional(rollbackFor = {Exception.class})
public class AdminServiceImpl implements AdminService {

    @Autowired
    private AdminDao adminDao;

    @Override
    public Admin selectAdmin(Map map) {
        return adminDao.selectAdmin(map);
    }

    @Override
    public Integer updateAdminLoginTime(Map map) {
        return adminDao.updateAdminLoginTime(map);
    }

    @Override
    public Integer updateAdmin(Admin admin) {
        return adminDao.updateAdmin(admin);
    }
}
